<!DOCTYPE html>
<html lang="en" manifest="header.appcache">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <meta name="author" content="bgemall.com">
    <meta name="description" content="购吧">
    <meta name="keywords" content="购吧">
    <meta http-equiv="Access-Control-Allow-Origin" content="*">
    <title>首页-购吧</title>
    <script src="js/edition.js"></script>   
    <link rel="stylesheet" href="css/base.css">
    <script>
       document.write("<l"+"ink rel='stylesheet' href='css/index.css?version="+edition+"'>")
    </script>
    <link rel="stylesheet" href="css/popover.css">
    <script src="js/jquery.js"></script>
    <script src="js/template.js"></script>
    <script src="js/jquery.SuperSlide.2.1.1.js"></script>
    <script src="js/popover.js"></script>
    <script src="js/jquery.cookie.js"></script>  
    <script> 
       document.write("<s"+"cript type='text/javascript' src='js/url.js?version="+edition+"'></scr"+"ipt>"); 
    </script>
    <script> 
       document.write("<s"+"cript type='text/javascript' src='js/index.js?version="+edition+"'></scr"+"ipt>"); 
    </script>
    <script> 
       document.write("<s"+"cript type='text/javascript' src='js/index_header.js?version="+edition+"'></scr"+"ipt>"); 
    </script>
    <script src="js/index_floor.js"></script>
    <script src="js/index_foot.js"></script>
    <script src="js/popover.js"></script>
    <script src="js/jquery.lazyload.min.js"></script>
    <script> 
       document.write("<s"+"cript type='text/javascript' src='js/login.js?version="+edition+"'></scr"+"ipt>"); 
    </script>    
    <script src="js/cookie.js"></script>  
    <!--<script type="text/javascript"src="http://qzonestyle.gtimg.cn/qzone/openapi/qc_loader.js" charset="utf-8" data-callback="true"></script>-->
    <script src="js/nav_hover.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <script type="text/javascript" src="https://unpkg.com/vue-router/dist/vue-router.js "></script>
    <!--<script src="https://unpkg.com/axios/dist/axios.min.js"></script>-->
</head>
<body >
	<div class="head_login">
		<div class="mod_head_wrap" style="height: 40px;background: #F5F5F5;">
			<div class="lefts">好物好价，购吧就买<span><img src="img/base/head_left.png"/>0592-6031-095</span></div>
			<div class="rights mod_login">
				<div class="yes_or_no">
					欢迎来到购吧网，请选择 <a href="../src/login/login.html?type=2">登陆</a>或者 <a href="../src/login/register.html">注册</a>
				</div>
			</div>
		</div>
	</div>
    <input type="hidden" class="nav_num" name="" value="1">    
    <header class="mod_head"><!-- 顶部内容 --></header>
    <!-- 导航条 start -->
    <!-- 导航条 end -->
    <!-- 楼层导航 start -->
    <!--<div class="mod_sidemenu" id="sideMenu">
        <div class="sidemenu_tit"><i></i><span>导航</span></div>
        <ul></ul>
        <script id="sideMenuTpl" type="text/html">
            {{ for (var i=0; i < sideMenuList.length;i++) { }}
                <li class="f{{=sideMenuList[i].index}}" data-target="f{{=sideMenuList[i].index}}"><span>{{=sideMenuList[i].index}}F</span><span>{{=sideMenuList[i].categoryName}}</span><i></i></li>
            {{ } }}
        </script>
    </div>-->
    <!-- 楼层导航 end -->
    <!-- 右边固定条 start -->
    <div class="mod_sidebar" >
        <div class="sidebar_wrap">
            <div class="sidebar_cont">
                <!-- <a class="ad" href="javascript:;"><i></i><span>活动广告</span></a> -->
                <a class="customer_service" href="tencent://message/?uin=2151577512&Site=http://vps.shuidazhe.com&Menu=yes"><i></i><span>客服</span></a>
                <a class="cart" href="src/cart/cart.html"><i></i><span>购物车</span></a>
                <a class="collection" href="src/member/member_favorites.html" style="padding-top: 28px;"><i></i><span>收藏</span></a>
                <!--<a class="follow_us" href="javascript:;"><i></i><span>关注我们</span></a>-->
                <!--<div class="follow_us_bg">
                    <div class="follow_us_wrap">
                        <div class="fu_01"><img src="img/qrcode/weibo.jpg" alt=""><p>官方微博</p></div>
                        <div class="fu_02"><img src="img/qrcode/weixin.jpg" alt=""><p>官方微信</p></div>
                        <div class="sanjiao"></div>
                    </div>
                </div>-->
            </div>
            <a href="javascript:0;" class="mod_totop" id="toTop"><i></i><span>返回顶部</span></a>
        </div>
    </div>
    <script>
        $(function(){
        	$('.cart').click(function(){
        		
        	})
            // 鼠标移入、移出 关注我们 显示隐藏二维码
            $('.follow_us').mouseover(function(){
                $('.follow_us_bg').css('display','block');
            });
            $('.follow_us').mouseout(function(){
                $('.follow_us_bg').css('display','none');
            });
        });
    </script>
    <!-- 右边固定条 end -->
    <!-- 主体内容 start -->
    <div class="mod_main" >
        <div class="mod_top">
            <!-- nav Start -->

            <!-- banner start -->
            <div class="mod_banner">
                <div class="hd">
                    <ul><!-- 轮播图 --></ul>
                </div>
                <div class="bd">
                    <ul><!-- 轮播图小点 --></ul>
                </div>
                <!-- 轮播图前后按钮 -->
                <a class="prev" href="javascript:void(0)"></a>
                <a class="next" href="javascript:void(0)"></a>    
            </div>
            <script id="bannerTop" type="text/html">
                {{ for(var b=0;b<bannerList.length;b++){ }}
                    <li><a href="{{=bannerList[b].jumpUrl}}" target="_blank"><img src="{{=bannerList[b].imgLink}}"></a></li>
                {{ } }}
            </script>
            <script id="bannerHd" type="text/html">
                {{ for(var i=0;i<bannerHdList.length;i++){ }}
                    <li>{{=bannerHdList[i].index}}</li>
                {{ } }}
            </script>
            <!-- banner end -->
            <div class="record">
            	<div class="record_head">
            		<img src="img/base/record_head_img.png"/>
            	</div>
            	<ul class=" record_ul">
            	</ul>
            </div>
            <script type="text/javascript" id="record_li">
            	{{ for(var i=0;i<record_li.length;i++){ }}
                    <li>
                    	{{=record_li[i].buyerName}}
                		在
                		{{=record_li[i].time}}
                		购买了
                		{{=record_li[i].goodsNum}}
                		份
                		{{=record_li[i].goodsName}} 
                	</li>
                {{ } }}
            </script>
        </div>

        <!-- 企业宣传广告 start -->
        <div class="mod_ad_banner" id="mod_ad_banner"></div>
        <script id="modAdBanner" type="text/html">
            {{ for(var b=0;b<AdBannerList.length;b++){ }}
                <a href="{{=AdBannerList[b].jumpUrl}}" target="_blank"><img src="{{=AdBannerList[b].imgLink}}" title="{{=AdBannerList[b].title}}"></a>
            {{ } }}
        </script>
        <!-- 企业宣传广告 end -->
        
        <!-- 商品楼层 start -->
        <div  class="mid_content" >
        	<div class="floor1 mod_floor"  id="app" v-cloak v-if="timeinfolist.length>0">
        		<div class="floor mod_floor" style="overflow: hidden;">
                    <div class="mod_floor_tit">
                        <span>限时抢购</span>
                        <a href="src/scarebuy/scarebuy.html">更多抢购>> </a>
                    </div>
                    <div class="time_box" >
                    	<!--<todo-item v-for="item in timeinfolist" :todo="item" :key="item.id"></todo-item>-->
                    	<div v-for="item in timeinfolist" :class="actshow==item.id?'time_item act':'time_item '"  @click="goodsinfos(item)">
                    		{{item.time}}
                    		<span v-show="item.status == 2&&item.lest ==1">热门</span>
                    		<span v-show="item.status == 2&&item.lest !=1">抢购中</span>
                    		<span v-show="item.status == 1">即将开始</span>
                    	</div>
                    </div>
                    <!--<div class="">
                    	<i>{{content.day}}</i>天<i>{{content.hour}}</i>小时<i>{{content.min}}</i>分钟<i>{{content.sec}}</i>秒后结束
                    </div>-->
                    <div class="mod_floor_content" style="position: relative;">
                        <div  class="floor_ad" style="position: absolute; ">
                        	<div class="countdown_box">
                        		<h4>{{next.startTime}}场</h4>
                        		<div class="yelbackbox"></div>
                        		<p>距离开始还剩</p>
                        		<div class="countdown">
                        			<i>{{content.hour}}</i>:<i>{{content.min}}</i>:<i>{{content.sec}}</i>
                        		</div>
                        	</div>
                        	<!--<img style="height: 440px;" src="img/countdown_back.jpg" />-->
                        </div>
                        <div class="floor_content">
                        	<ul class="limit">
                        		<li v-for="item in goodsinfolist.goodsList" :key="item.goodsCommonid" @click="goto(item)">    
                        			<div class="limit_img">
                        				<img :src="item.goodsImage">
                        			</div>
                        			<div class="limit_center">
                        				<h4>{{item.goodsName}}</h4>
                        				<div class="progress_box">
                        					<div class="progress_bar">
                        						<div class="progress" :style="{width:item.width+'%'}"></div>
                        					</div>
                        					<span>{{item.salesStorage}}/{{item.participateStorage}}</span>
                        				</div>
                        				<div class="price">
                        					限时价： ￥<span>{{item.activityPrice}}</span><del>￥{{item.goodsPrice}}</del>
                        				</div>
                        				<!--<button v-if="item.salesStorage < item.participateStorage">立即抢购</button>-->
                        				<button v-if="item.salesStorage==item.participateStorage&&timestat.status == 2">已售罄</button>
                        				<button v-else-if="timestat.status == 1">即将开始</button>
                        				<button v-else @click.stop="gobuy(item.goodsId)">立即抢购</button>
                        			</div>
                        		</li>
                        	</ul>
                        </div>
                    </div>
                </div>
        	</div>
            <div class="floor1 mod_floor hidd"></div>
            <div class="floor1 mod_floor hidd"></div>
            <div class="floor1 mod_floor hidd"></div>
        </div>
        <!-- 楼层整体框架模板 -->
        <script id="modFloor" type="text/html">
            {{ for( var i=0;i < floorList.length;i++){ }}
                <div class="floor mod_floor" id="f{{=floorList[i].index}}" data-floor-id="{{=floorList[i].index}}F" data-floor-name="{{=floorList[i].categoryName}}">
                    <div class="mod_floor_tit">
                        <span>{{=floorList[i].index}}F&nbsp;&nbsp;{{=floorList[i].categoryName}}</span>
                    </div>
                    <div class="mod_floor_content">
                        <!--<div  class="floor_ad"></div>-->
                        <div class="floor_content">
                            <ul class="floor_goods">
                                
                            </ul>
                            <div class="mod_floor_brand" id="mod_floor_brand{{=floorList[i].index}}">
                                <a class="prev" href="javascript:void(0)"></a>
                                <div class="bd">
                                    <ul></ul>
                                </div>
                                <a class="next" href="javascript:void(0)"></a>
                            </div>
                        </div>
                    <div>
                <div>
            {{ } }}
        </script>
        <!-- 楼层商品显示模板 -->
        <script id="floorGoods" type="text/html">
            {{ for( var i=0;i < floorGoodsList.length;i++){ }}
                <li>
                    <a href="src/goods/goods_detail.html?goodsId={{=floorGoodsList[i].goodsId}}" title="{{=floorGoodsList[i].name}}" target='_blank'>
                        <div class="floor_goods_img"><img src="{{=floorGoodsList[i].goodsImg}}"></div>
                        <span class="floor_goods_name">{{=floorGoodsList[i].name}}</span>
                        <span class="floor_goods_price">
                            <label>￥{{=floorGoodsList[i].unitPrice}}</label>
                            <del>￥{{=floorGoodsList[i].marketPrice}}</del>
                        </span>
                    </a>
                </li>
            {{ } }}
        </script>
        <!-- 楼层左边小广告 -->
        <script id="leftAdv" type="text/html">
            {{ for( var i=0;i < leftAdvList.length;i++){ }}
                <a href="javascript:;" class="{{=leftAdvList[i].categoryId}}"><img src="{{=leftAdvList[i].leftAdvImg}}"></a>
            {{ } }}
        </script>
        <!-- 楼层品牌 -->
        <script id="floorBrand" type="text/html">
            {{ for( var i=0;i < floorBrandList.length;i++){ }}
                <li><a title="{{=floorBrandList[i].BrandName}}" href="src/search/search_list.html?keyword={{=floorBrandList[i].BrandName}}"><img src="{{=floorBrandList[i].brandPic}}" /></a></li>
            {{ } }}
        </script>
        <!-- 商品楼层 end -->

        <!-- 优秀案例 start -->
        <div class="floor mod_case" id="f11" data-floor-id="11F" data-floor-name="优秀案例">
            <div class="mod_case_tit">
                <span>优秀案例</span>
                <a href="src/case/case.html?type=0" target="_blank">更多案例>></a>
            </div>
            <ul class="mod_case_list">
                <li>
                    <a href="javascript:;">
                        <div class="case_pic"><img src="img/case/case_01.jpg" alt=""></div>
                        <div class="case_text">
                            <span><i>1</i>太平洋保险厦门分公司</span>
                            <p>与中国太平洋保险厦门分公司进行2017年中秋博饼合作</p>
                        </div>
                    </a>
                </li>
                <li>
                    <a href="javascript:;">
                        <div class="case_pic"><img src="img/case/case_03.jpg" alt=""></div>
                        <div class="case_text">
                            <span><i>2</i>东莞证券厦门分公司</span>
                            <p>与东莞证券厦门分公司进行2017年中秋博饼合作</p>
                        </div>
                    </a>
                </li>
                <li>
                    <a href="javascript:;">
                        <div class="case_pic"><img src="img/case/case_02.jpg" alt=""></div>
                        <div class="case_text">
                            <span><i>3</i>厦门航空</span>
                            <p>与厦门航空公司进行2017年中秋博饼合作</p>
                        </div>
                    </a>
                </li>
                <li>
                    <a href="javascript:;">
                        <div class="case_pic"><img src="img/case/case_04.jpg" alt=""></div>
                        <div class="case_text">
                            <span><i>4</i>厦门金龙客车有限公司</span>
                            <p>与厦门金龙客车有限公司进行2017年中秋博饼合作</p>
                        </div>
                    </a>
                </li>
            </ul>
            <div class="case_circle_01"></div>
            <div class="case_circle_02">
                <span>合作</span>
                <p>cooperation</p>
            </div>
        </div>
        <script>
            $(function(){
                $('.mod_case li').click(function(){
                    kf();   // 正在开发中
                });
            })
        </script>
        <!-- 优秀案例 end -->

        <!-- 关于购吧 & 联系我们 start -->

        <div class="about_connect">
            <div class="about_wrap">
                <div class="about_tit"><img src="../img/base/about.png" alt=""></div>
                <ul class="about_content">
                    <li>
                        <div class="about_subtit">
                            <span>购吧动态</span>
                        </div>
                        <ul class="dangmai_dt"><!-- 购吧动态 --></ul>
                        <a href="javascript:;" class="about_more kfing">查看更多>></a>
                    </li>
                    <li>
                        <div class="about_subtit">
                           	<span>购吧助手</span>
                        </div>
                        <ul class="dangmai_zs"><!-- 购吧助手 --></ul>
                        <a href="javascript:;" class="about_more kfing">查看更多>></a>
                    </li>
                </ul>
            </div>
            <div class="about_wrap" style="width: 397px;">
                <div class="about_tit"><img src="../img/base/connect.png" alt=""></div>
                <ul class="about_content" style="text-align: center;">
                    <li style="height:165px;display:block;margin: 0 auto;width: 100%;">
                        <div class="about_subtit">
                            <span>联系方式</span>
                        </div>
                        <ul class="connect_left">
                            <li><a href="javascript:;">售前电话&nbsp;&nbsp;&nbsp;&nbsp;0592 - 2033 - 321</a></li>
                            <li><a href="javascript:;">售后电话&nbsp;&nbsp;&nbsp;&nbsp;0592 - 2033 - 321</a></li>
                            <li><a href="javascript:;">售后邮箱&nbsp;&nbsp;&nbsp;&nbsp;2151577512@qq.com</a></li>
                        </ul>   
                    </li>
                    <!--<li style="height:165px;">
                        <div class="about_subtit">
                            <i>2</i><span>新媒体</span>
                        </div>
                        <ul class="connect_right">
                            <li><img src="img/qrcode/weibo.jpg" alt=""><span>官方微博</span></li>
                            <li><img src="img/qrcode/weixin.jpg" alt=""><span>官方微信</span></li>
                        </ul>
                    </li>-->
                </ul>
            </div>
        </div>
        <!-- 购吧动态模板 -->
        <script id="aboutDt" type="text/html">
            {{ for( var i=0;i < aboutDtList.length;i++){ }}
                <li><a href="javascript:;" class="kfing">{{=aboutDtList[i].title}}</a></li>
            {{ } }}
        </script>
        <script id="aboutZs" type="text/html">
            {{ for( var i=0;i < aboutZsList.length;i++){ }}
                <li><a href="javascript:;" class="kfing">{{=aboutZsList[i].title}}</a></li>
            {{ } }}
        </script>
        
        <!-- 关于购吧 & 联系我们 end -->
        
        
        <!--限时抢购-->
        <!--<script id="aboutgs" type="text/html">
            {{ for( var i=0;i < aboutgsList.length;i++){ }}
            	<div class="time_item act" data-id = "">
            		{{=aboutgsList[i].time}}
            	</div>
            {{ } }}
        </script>-->
    </div>

    <!-- 主体内容 end -->
    <!-- 网站底部 start -->
    <footer class="mod_foot"></footer>
    <!--<script type="text/javascript" src="js/vue.js" ></script>-->
    <!--<script src="https://cdn.jsdelivr.net/npm/vue@2.5.17/dist/vue.js"></script>-->
    
    <script type="text/javascript">
    	window.onload = function(){
    	var app = new Vue({
		  el: '#app',
		  data: {
		  		timeinfolist:{},
			    goodsinfolist:{},
			    actshow:'',
			    godsid:'',
			    content: {
					day: '',
					hour: '',
					min: '',
					sec: '',
					achieve: false
				},
				next:{},
				timestat:{}
		  },
		  methods: {
		    timeinfo: function () {
		    	var that =this
		    	  $.ajax({
	                    type: 'post',
	                    url: 'http://api.bgemall.com/shop/flash_sale_goods/getFlashSaleList',
	                    data:{
	                    	type:'1'
	                    },
	                    dataType:'json',
	                    success:function(res) {
	                    	if(res.code==0){
	                    		that.timeinfolist = res.data
							  	if(that.timeinfolist.length>0){
							  		that.godsid = that.timeinfolist[0].id
								  	that.actshow = that.godsid
								  	that.timestat = that.timeinfolist[0]
								  	if(that.timeinfolist.length>1){
								  		for(let i = 0; i<that.timeinfolist.length;i++){
									  		let c = i+1
									  		if(that.timeinfolist[c]){
									  			if(that.timeinfolist[i].status == "2" &&that.timeinfolist[c].status == "1" ){
									  				that.$set(that.timeinfolist[i], "lest", '1')
									  				that.godsid = that.timeinfolist[i].id
								  					that.actshow = that.godsid
								  					that.goodsinfolist = {}
							  						that.goodsinfo(that.timeinfolist[i].id);
										  		}
									  			else{
										  			that.goodsinfo()
										  		}
									  		}
//									  		else{
//										  			that.goodsinfo()
//										  		}
								  		}
								  	}else{
							  			that.goodsinfo()
							  		}
							  	}
	                    	}
	                    }
	               });
		    },
		    countdowm: function(timestamp) {
		    	let self = this;
		    	let nowTime = new Date();
				let endTime = new Date(self.next.timeRemaining * 1000);
				let t = endTime.getTime() - nowTime.getTime();
				if(self.next.timeRemaining !='' && self.next.timeRemaining != null){
					if(t<=0){
						console.log(1)
						
						self.timeinfo();
						
					}
				}else{
					self.content.day = "00";
					self.content.hour = "00";
					self.content.min = "00";
					self.content.sec = "00";
					return;
				}
				
				let timer = setInterval(function() {
					let nowTime = new Date();
					let endTime = new Date(self.next.timeRemaining * 1000);
					let t = endTime.getTime() - nowTime.getTime();
//					console.log(endTime)
//					let t = self.next.nextTime;
//					console.log(nowTime)
					self.content.achieve = true
					if(t > 0) {
						let day = Math.floor(t / 86400000);
						let hour = Math.floor((t / 3600000) % 24);
						let min = Math.floor((t / 60000) % 60);
						let sec = Math.floor((t / 1000) % 60);
						hour = hour < 10 ? "0" + hour : hour;
						min = min < 10 ? "0" + min : min;
						sec = sec < 10 ? "0" + sec : sec;
						let format = '';
						//                  if(day > 0){
						self.content.day = day;
						self.content.hour = hour;
						self.content.min = min;
						self.content.sec = sec;
						//                  }
						self.content.achieve = true
					} else {
						self.content.achieve = false
						clearInterval(timer);
						self._callback();
//						self.goodsinfo();
					}
				}, 100);
			},
			 _callback(){
			 	let self = this;
               if(self.callback && self.callback instanceof Function){
                     self.callback(...self);
                 }
           },
		    goodsinfo:function(index){
		    	var that =this
		    	that.goodsinfolist = {}
//		    	console.log(that.timeinfolist)
 				$.ajax({
	                    type: 'post',
	                    url: 'http://api.bgemall.com/shop/flash_sale_goods/getFlashSaleGoods',
	                    dataType:'json',
	                    data:{
	                    	id:index||that.godsid,
		    				getAll:'2'
	                    },
	                    success:function(res) {
						  	that.goodsinfolist = res.data
						  	that.next = res.data.next
						  	for(let i = 0; i<that.goodsinfolist.goodsList.length;i++){
						  		let a =that.goodsinfolist.goodsList[i].salesStorage/that.goodsinfolist.goodsList[i].participateStorage*100
						  		 that.$set(that.goodsinfolist.goodsList[i], "width", a)
						  	}
						  	that.countdowm()
	                    }
	              });
		    },
		    goodsinfos:function(item){
		    	var that =this
//		    	console.log(item)
				that.goodsinfolist = {}
		    	that.timestat = item
		    	that.actshow = item.id||''
 				$.ajax({
	                    type: 'post',
	                    url: 'http://api.bgemall.com/shop/flash_sale_goods/getFlashSaleGoods',
	                    dataType:'json',
	                    data:{
	                    	id:item.id,
		    				getAll:'2'
	                    },
	                    success:function(res) {
						  	that.goodsinfolist = res.data
						  	for(let i = 0; i<that.goodsinfolist.goodsList.length;i++){
						  		let a =that.goodsinfolist.goodsList[i].salesStorage/that.goodsinfolist.goodsList[i].participateStorage*100
						  		 that.$set(that.goodsinfolist.goodsList[i], "width", a)
						  	}
						  	console.log(that.goodsinfolist)
						  	that.countdowm()
	                    }
	              });
		    },
		    goto(item){
		    	var that =this
		    	if(item.salesStorage==item.participateStorage){
		    		alert("商品已售罄")
		    	}else if(that.timestat.status == 1){
		    		alert("抢购未开始")
		    	}
		    	else{
		    		window.location.href="src/goods/goods_detail.html?goodsId="+item.goodsId; 
		    	}
		    },
		    gobuy(goodsId){
		    	var goods_user=1+'&'+goodsId+'&'+0
		    	console.log(goods_user)
                $.cookie('goods_user',goods_user,{path:'/'});
		   		if($.cookie('user')!=''&&$.cookie('user')!=null){
                    strs=$.cookie('user').split(",")
                    var token=''
                    for(var i in strs){
                        token=strs[6]
                    }
                    $.ajax({
		                url:new_url+'shop/buy/getSettleGoodsList',
		                data:{isFromCart:'0',token:token,goodsId:goodsId,buyNum:1},
		                dataType:'json',
		                type:'post',
		                success:function(n){ 
		                	if(n.code!='0'){
                                tc(n.message)
                                if(n.data='1005'){
                                    $.cookie('user','',{path:'/'})
                                    setTimeout(function(){
                                        window.location.href='/src/login/login.html?type=2'
                                    },500)
                                }
                                return false;
                            }
                            else{
                                tc(n.message)
                                if($.cookie('my_cookie')!=null&&$.cookie('my_cookie')!=''){
                                    $.cookie('my_cookie','',{path:'/'});
                                }
                                window.location.href='/src/cart/pay_commit.html' 
                            }
	                	}
	          		})
              	}else{ 
              		window.location.href='/src/login/login.html?type=2'
                    setTimeout(function(){
                        $('.popover_m, .site_bg').fadeIn()
                        $('.gb_01, .popover_m').click(function(){
                            $('.popover_m, .site_bg').fadeOut()
                        })
                    },200)
                }
		   	},
		  },
		  mounted() {
		  	this.timeinfo()
		  }
		})
    }
    </script>
    <script>
        $(function(){
            $('.footer_ul a').each(function(){
                var newHref = $(this).attr('href');
                if(newHref!='javascript:;'){
                    $(this).attr('href','src'+newHref);
                }
            })
        });
    </script>
    <!-- 网站底部 end -->
    <script type="text/javascript">
        $(function(){
            // 轮播图配置
            $(".mod_banner").slide({mainCell:".bd ul",easing:"linear",effect:"left",delayTime:1000,autoPlay:true});
            $('.to_top').remove();      // 移除 返回顶部箭头 
        }); 
        $(".kfing").click(function(){ 
            kf(); 
        }); 
        $(function(){ 
          $('.mod_menu_list').show(); 
        }); 
    </script> 
</body> 
</html> 
<script> 
    $(function(){ 
        var url=window.location.href; 
        var code=url.split('?code=')[1]; 
        if(code!=undefined){ 
            var new_code=code.split('&')[0]; 
            $.ajax({ 
                url:new_url+'shop/oauth/oauthLogin', 
                type:'post', 
                data:{oauthType:'1',code:new_code}, 
                dataType:'json', 
                success:function(e){ 
                    if(e.code=='2007'){ 
                        tc(e.message);
                        window.location.href='src/login/binding.htm?oauthId='+e.data.oauthId; 
                    }  
                    if(e.code=='0'){ 
                        tc(e.message); 
                        var mycars = new Array(); 
                        mycars[0] = e.data.name; 
                        mycars[1] = e.data.nickName; 
                        mycars[2] = e.data.phone; 
                        mycars[3] = e.data.avatar; 
                        mycars[4] = e.data.truename; 
                        mycars[5] = e.data.memberId; 
                        mycars[6] = e.data.token; 
                        mycars[7] = 
                        $.cookie('user',mycars,{path:'/'}); 
                        window.history.go(-1); 
                        return false; 
                    } 
                } 
            }); 
        } 
    }); 
</script> 